package com.RedAndBlack.redandblack;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.Menu;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;


public class MainActivity extends Activity{
	
			Button btStart;
    		Button btHelp;


	@Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.main);
        
        btStart = (Button) findViewById(R.id.btStart);
        
        btHelp  = (Button) findViewById(R.id.btHelp);
        
        OnClickListener listMenu = new OnClickListener() {
			
			@Override
			public void onClick(View v) {
				
				switch (v.getId()) {
				case  R.id.btStart:
					Intent intent = new Intent(MainActivity.this , ActivityGame.class );
					startActivity(intent);
					break;
					
				case R.id.btHelp:
					Intent intent2 = new Intent(MainActivity.this , ActivityHelP.class);
					startActivity(intent2);
					break;
					
				default:
					break;
				}
				
			}
		};
       
		
		btStart.setOnClickListener(listMenu);
		btHelp.setOnClickListener(listMenu);
		
		
    };    
    
 		
    @Override
    public boolean onCreateOptionsMenu(Menu menu) {
        getMenuInflater().inflate(R.menu.main, menu);
        return true;
    }
    
    
    
}
